import request from '@/utils/request'

export function loadAll(data) {
	return request({
		url: '/goods',
		method: 'post',
		data
	})
}

export function loadAllGood() {
	return request({
		url: '/goods',
		method: 'get',
	})
}

export function update(data) {
	return request({
		url: '/goods',
		method: 'put',
		data
	})
}

export function delGood(data) {
	return request({
		url: '/goods/'+data,
		method: 'delete',
	})
}

export function delGoods(data) {
	return request({
		url: '/goods/delMany',
		method: 'delete',
		data
	})
}


export function findType(data) {
	return request({
		url: '/goods/type',
		method: 'post',
		data
	})
}

export function loadSize(data) {
	return request({
		url: '/goods/size',
		method: 'post',
		data
	})
}
